package com.awn.weidian.demo.mapper;


import com.awn.weidian.demo.pojo.Msgs;

import org.apache.ibatis.annotations.*;

import java.util.List;

@Mapper
public interface IMsgs {

    @Select("select * from msgs ")
    public List<Msgs> selectMsgs();

    @Select("select * from msgs where mid=#{mid}")
    public List<Msgs> showMsgs(int mid);

    @Update("update msgs set mgshead=#{mgshead},msg=#{msg} where mid=#{mid}")
    public int updateMsgs(Msgs msgs);

    @Delete("delete from msgs where mid = #{mid}")
    public int deleteMsgs(int mid);

    @Insert("insert into msgs(mgshead,msg) values(#{mgshead},#{msg})")
    public int addMsgs(Msgs msgs);

    




}
